﻿@model KinoDB.Viewmodels.Internal.CreateDuty.CreateDutyViewModel
@{
    ViewBag.Title = "Create Duty";
}

<h2>Neuer Dienst</h2>

@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()
    
    <div class="form-horizontal">
        <h3>@Model.Name</h3>
        <hr />
        @Html.ValidationSummary(true)

        <div class="form-group">
            @Html.Label("Startzeit", new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.StartTime.Date, new { @Value = DateTime.Now.Date })
                @Html.ValidationMessageFor(model => model.StartTime.Date)
            </div>
            <div class="col-md-10">
                @Html.EditorFor(model => model.StartTime.TimeOfDay, new { @Value = DateTime.Now.TimeOfDay })
                @Html.ValidationMessageFor(model => model.StartTime.TimeOfDay)
            </div>
        </div>

        <div class="form-group">
            @Html.Label("Dauer", new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.Duration, new { @Value = 8 })
                @Html.ValidationMessageFor(model => model.Duration)
            </div>
        </div>
        
        <div class="form-group">
            <div class="col-md-offset-2 col-md-10">
                <input type="submit" value="Save" class="btn btn-default" />
            </div>
        </div>
    </div>
}

<div>
    @Html.ActionLink("Back to List", "DutyManagement")
</div>